pub fn for_fn() {
    // a..=b can be used for a range that is inclusive on both ends.
    for e in 1..=100 {
        if e == 100 {
            println!("loop, here is {}", e);
        }
    }

    let names = vec!["foo", "bar", "baz"];
    for name in names.iter() {
        match name {
            &"foo" => println!("select foo {}", name),
            _ => println!("Hello {}", name),
        }
    }
    for name in names {
        match name {
            "foo" => println!("1 select foo {}", name),
            _ => println!("1 Hello {}", name),
        }
    }
    let mut names = vec!["foo", "bar", "baz"];
    for name in names.iter_mut() {
        *name = match name {
            &mut "foo" => "There is a mut foo",
            _ => "Hello",
        }
    }
    println!("names: {:?}", names);
}
